<ul class="nav">
  <li class="dropdown list-message">
    <a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false" data-drupal-link-system-path="manage/notifications">
      {# 消息 #}
      <i class="iconfont icon-bell"></i> 
      {# 私信 #}
      {# <i class="iconfont icon-mail"></i> #}
      <span class="label label-warning" {# or label-succes #}
        data-view="Drupal.Dyniva.GeneralView"
        data-model="Drupal.dyniva_notifications.NoticeViewModel"
        data-template="notifications_toolbar_total_template"></span>
    </a>
    <ul class="dropdown-menu">
      <li class="dropdown-menu-arrow"></li>
      <li class="header"
        data-view="Drupal.Dyniva.GeneralView"
        data-model="Drupal.dyniva_notifications.NoticeViewModel"
        data-template="notifications_toolbar_tip_template">
      </li>
      <li>
        <ul class="menu"
          data-view="Drupal.Dyniva.ListView"
          data-item-view="Drupal.dyniva_notifications.NoticeItemView"
          data-collection="Drupal.dyniva_notifications.NoticeCollection"
          data-empty-template="notifications_toolbar_empty_template"
          >
        </ul>
      </li>
      {# <li class="footer"><a href="{{path('dyniva_message.notifications.collection')}}">{{'View all'|t}}</a></li> #}
      <li class="footer clearfix">
        <div class="footer-item">
          <a href="{{path('view.dyniva_notifications.manage')}}" target="_blank">{{'View all'|t}}</a>
        </div>
        <div class="footer-item"
          data-view="Drupal.dyniva_notifications.MakeAllReadView"
          data-model="Drupal.dyniva_notifications.NoticeViewModel"
          data-template="notifications_toolbar_make_all_read"></div>
      </li>
    </ul>
  </li>
</ul>

<script type="text/template" id="notifications_toolbar_total_template">
<%=total%>
</script>

<script type="text/template" id="notifications_toolbar_tip_template">
{{'You have <%=total%> notifications'|t}}
</script>

<script type="text/template" id="notifications_toolbar_empty_template">
<p class="empty">{{'No message.'|t}}</p>
</script>

<script type="text/template" id="notifications_toolbar_make_all_read">
<a href="#">{{'Make as All Read'|t}}</a>
</script>
